function [p q] = TimeDiscretizers(dt,option)
% Following Algorithms are implemented in the current study
% 1. Fully Implicit Theta Scheme
% 2. Fully Implicit BDF Two parameter Scheme
% 3. Explicit Leap Frog Scheme
% 4. Semi Implicit BDF - By adjusting parameters = Semi Implicit
% Trapezoidal
% 5. Semi Implicit Trapezoidal with Upwinding Discretization
% 6. Semi Implicit Trapezoidal with Central Discretization
% 7. Fully Implicit with Upwinding
global Ux Uy  h  g  p  q tmax Lx Ly dx dy L Nx Ny y nt;

%Reinitialize the variables
pi1=1;
qi=1;

r=zeros(Ny,Nx);
for j=1:Nx
    for i=1:Ny
        index = (j-1)*Ny+i;
        p(index,1) = pi1*cos(5*pi*j*dx/Lx);
        r(i,j) = p(index);
        q(index,1) = qi;
    end
end


nt = round(tmax/dt);   % number of time steps
%h1 = plot(xplot,p,'yDataSource','p');


if (option ==1)
    disp('1. Fully Implicit Theta Scheme\n');
    beta=0.5;
%     beta = input('Enter the value of theta: \n');
%     if (beta ==0)
%         X = sprintf('This is FTCS method, very unstable. Chose very very small time step below %d for stable Result!' , dt1);
%         disp(X);
%     end
    [p q] = implicit_theta(dt,beta);
    
elseif (option==2)
    disp('2. Fully Implicit BDF Two parameter Scheme \n');
    [p q] = BDF2(dt);
    
elseif (option ==3)
    disp('3. Explicit Leap Frog \n');
    [p q] = leapfrog(dt);
elseif (option==4)
    display(' Semi Implicit Scheme BDF ');
    beta = input('Enter the value of theta:\n');
    alpha = input('Enter the value of  alpha\n');
    [p q] = SemiImplicit_BDF(alpha,beta);
    d
elseif (option ==5)
    display(' Semi Implicit Scheme Trapezoidal with upwinding Discretization ');
    [p q] = SemiImplicit_Trapezoidal_Upwinding(dt);
    
elseif (option ==6)
    display(' Semi Implicit Scheme Trapezoidal ');
    [p q] = SemiImplicit_Trapezoidal(dt);
elseif (option ==7)
    display(' Implicit Scheme  Two Parameter Model, Upwinding');
    [p q] = BDF2_Upwinding(dt);   
    
end




